import service from './request'

export function getGoodsList (params = {}) {
  return service({
    url: '/goods',
    method: 'get',
    params,
  })
}

export function goodsCreate (goods) {
  return service({
    url: '/goods/add',
    method: 'post',
    data: goods,
  })
}

export function goodsEdit (goods) {
  return service({
    url: '/goods/edit',
    method: 'post',
    data: goods,
  })
}

export function goodsDelete (ids) {
  return service({
    url: '/goods/delete',
    method: 'post',
    data: { ids },
  })
}
